From: Richard M. Stallman Date: Wed, 25 May 1994 04:41:21 +0000 (+0000) Subject: (outline-chart-subtree): Include outline-next-heading in loop conditions X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~91386 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=e6a9aec70b6f0bdfa7ed2bde048e4c84aee213ca;p=emacs.git (outline-chart-subtree): Include outline-next-heading in loop conditions to detect end-of-buffer (and avoid infinite loop). --- diff --git a/lisp/allout.el b/lisp/allout.el index 8f87eca6666..dde6c4cdca4 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -1453,9 +1453,9 @@ starting point, and PREV-DEPTH is depth of prior topic." (or (outline-next-sibling curr-depth) ;; or no more siblings - proceed to ;; next heading at lesser depth: - (while (<= curr-depth - (outline-recent-depth)) - (outline-next-heading))) + (while (and (<= curr-depth + (outline-recent-depth)) + (outline-next-heading)))) (outline-next-heading))) ((and (< prev-depth curr-depth)